package com.yidian.mapper;

import com.yidian.entity.Article;
import com.yidian.entity.ArticleChannelExample;
import com.yidian.entity.ArticleChannelKey;
import java.util.List;
import org.apache.ibatis.annotations.Param;

public interface ArticleChannelMapper {
    int countByExample(ArticleChannelExample example);

    int deleteByExample(ArticleChannelExample example);

    int deleteByPrimaryKey(ArticleChannelKey key);

    int insert(ArticleChannelKey record);

    int insertSelective(ArticleChannelKey record);

    List<ArticleChannelKey> selectByExample(ArticleChannelExample example);

    int updateByExampleSelective(@Param("record") ArticleChannelKey record, @Param("example") ArticleChannelExample example);

    int updateByExample(@Param("record") ArticleChannelKey record, @Param("example") ArticleChannelExample example);

    // 根据频道id查询下面所有的文章(获取频道的文章列表)
    List<Article> selectAllArticleByChannelId(long channelId);

    // 获取所有的文章(获取频道的文章列表)
    List<Article> selectAllArticle();
}